package com.gesee.zyspps.db;

import android.database.sqlite.SQLiteDatabase;

import java.util.Map;

import de.greenrobot.dao.AbstractDao;
import de.greenrobot.dao.AbstractDaoSession;
import de.greenrobot.dao.identityscope.IdentityScopeType;
import de.greenrobot.dao.internal.DaoConfig;

import com.gesee.zyspps.db.CmsPoints;
import com.gesee.zyspps.db.CmsDbNum;
import com.gesee.zyspps.db.CmsPointsName;
import com.gesee.zyspps.db.CmsPipelineField;
import com.gesee.zyspps.db.CmsFeature;
import com.gesee.zyspps.db.CmsLine;
import com.gesee.zyspps.db.CmsPicture;
import com.gesee.zyspps.db.CmsPipePoint;
import com.gesee.zyspps.db.CmsSpecialLine;

import com.gesee.zyspps.db.CmsPointsDao;
import com.gesee.zyspps.db.CmsDbNumDao;
import com.gesee.zyspps.db.CmsPointsNameDao;
import com.gesee.zyspps.db.CmsPipelineFieldDao;
import com.gesee.zyspps.db.CmsFeatureDao;
import com.gesee.zyspps.db.CmsLineDao;
import com.gesee.zyspps.db.CmsPictureDao;
import com.gesee.zyspps.db.CmsPipePointDao;
import com.gesee.zyspps.db.CmsSpecialLineDao;

// THIS CODE IS GENERATED BY greenDAO, DO NOT EDIT.

/**
 * {@inheritDoc}
 * 
 * @see de.greenrobot.dao.AbstractDaoSession
 */
public class DaoSession extends AbstractDaoSession {

    private final DaoConfig cmsPointsDaoConfig;
    private final DaoConfig cmsDbNumDaoConfig;
    private final DaoConfig cmsPointsNameDaoConfig;
    private final DaoConfig cmsPipelineFieldDaoConfig;
    private final DaoConfig cmsFeatureDaoConfig;
    private final DaoConfig cmsLineDaoConfig;
    private final DaoConfig cmsPictureDaoConfig;
    private final DaoConfig cmsPipePointDaoConfig;
    private final DaoConfig cmsSpecialLineDaoConfig;

    private final CmsPointsDao cmsPointsDao;
    private final CmsDbNumDao cmsDbNumDao;
    private final CmsPointsNameDao cmsPointsNameDao;
    private final CmsPipelineFieldDao cmsPipelineFieldDao;
    private final CmsFeatureDao cmsFeatureDao;
    private final CmsLineDao cmsLineDao;
    private final CmsPictureDao cmsPictureDao;
    private final CmsPipePointDao cmsPipePointDao;
    private final CmsSpecialLineDao cmsSpecialLineDao;

    public DaoSession(SQLiteDatabase db, IdentityScopeType type, Map<Class<? extends AbstractDao<?, ?>>, DaoConfig>
            daoConfigMap) {
        super(db);

        cmsPointsDaoConfig = daoConfigMap.get(CmsPointsDao.class).clone();
        cmsPointsDaoConfig.initIdentityScope(type);

        cmsDbNumDaoConfig = daoConfigMap.get(CmsDbNumDao.class).clone();
        cmsDbNumDaoConfig.initIdentityScope(type);

        cmsPointsNameDaoConfig = daoConfigMap.get(CmsPointsNameDao.class).clone();
        cmsPointsNameDaoConfig.initIdentityScope(type);

        cmsPipelineFieldDaoConfig = daoConfigMap.get(CmsPipelineFieldDao.class).clone();
        cmsPipelineFieldDaoConfig.initIdentityScope(type);

        cmsFeatureDaoConfig = daoConfigMap.get(CmsFeatureDao.class).clone();
        cmsFeatureDaoConfig.initIdentityScope(type);

        cmsLineDaoConfig = daoConfigMap.get(CmsLineDao.class).clone();
        cmsLineDaoConfig.initIdentityScope(type);

        cmsPictureDaoConfig = daoConfigMap.get(CmsPictureDao.class).clone();
        cmsPictureDaoConfig.initIdentityScope(type);

        cmsPipePointDaoConfig = daoConfigMap.get(CmsPipePointDao.class).clone();
        cmsPipePointDaoConfig.initIdentityScope(type);

        cmsSpecialLineDaoConfig = daoConfigMap.get(CmsSpecialLineDao.class).clone();
        cmsSpecialLineDaoConfig.initIdentityScope(type);

        cmsPointsDao = new CmsPointsDao(cmsPointsDaoConfig, this);
        cmsDbNumDao = new CmsDbNumDao(cmsDbNumDaoConfig, this);
        cmsPointsNameDao = new CmsPointsNameDao(cmsPointsNameDaoConfig, this);
        cmsPipelineFieldDao = new CmsPipelineFieldDao(cmsPipelineFieldDaoConfig, this);
        cmsFeatureDao = new CmsFeatureDao(cmsFeatureDaoConfig, this);
        cmsLineDao = new CmsLineDao(cmsLineDaoConfig, this);
        cmsPictureDao = new CmsPictureDao(cmsPictureDaoConfig, this);
        cmsPipePointDao = new CmsPipePointDao(cmsPipePointDaoConfig, this);
        cmsSpecialLineDao = new CmsSpecialLineDao(cmsSpecialLineDaoConfig, this);

        registerDao(CmsPoints.class, cmsPointsDao);
        registerDao(CmsDbNum.class, cmsDbNumDao);
        registerDao(CmsPointsName.class, cmsPointsNameDao);
        registerDao(CmsPipelineField.class, cmsPipelineFieldDao);
        registerDao(CmsFeature.class, cmsFeatureDao);
        registerDao(CmsLine.class, cmsLineDao);
        registerDao(CmsPicture.class, cmsPictureDao);
        registerDao(CmsPipePoint.class, cmsPipePointDao);
        registerDao(CmsSpecialLine.class, cmsSpecialLineDao);
    }
    
    public void clear() {
        cmsPointsDaoConfig.getIdentityScope().clear();
        cmsDbNumDaoConfig.getIdentityScope().clear();
        cmsPointsNameDaoConfig.getIdentityScope().clear();
        cmsPipelineFieldDaoConfig.getIdentityScope().clear();
        cmsFeatureDaoConfig.getIdentityScope().clear();
        cmsLineDaoConfig.getIdentityScope().clear();
        cmsPictureDaoConfig.getIdentityScope().clear();
        cmsPipePointDaoConfig.getIdentityScope().clear();
        cmsSpecialLineDaoConfig.getIdentityScope().clear();
    }

    public CmsPointsDao getCmsPointsDao() {
        return cmsPointsDao;
    }

    public CmsDbNumDao getCmsDbNumDao() {
        return cmsDbNumDao;
    }

    public CmsPointsNameDao getCmsPointsNameDao() {
        return cmsPointsNameDao;
    }

    public CmsPipelineFieldDao getCmsPipelineFieldDao() {
        return cmsPipelineFieldDao;
    }

    public CmsFeatureDao getCmsFeatureDao() {
        return cmsFeatureDao;
    }

    public CmsLineDao getCmsLineDao() {
        return cmsLineDao;
    }

    public CmsPictureDao getCmsPictureDao() {
        return cmsPictureDao;
    }

    public CmsPipePointDao getCmsPipePointDao() {
        return cmsPipePointDao;
    }

    public CmsSpecialLineDao getCmsSpecialLineDao() {
        return cmsSpecialLineDao;
    }

}
